package com.goalias.feign;

import com.goalias.feign.domain.dto.EmailDto;
import com.goalias.resp.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

//@FeignClient(name = "ability-expansion", path = "/ability")
@FeignClient(name = "gateway-security", path = "/ability",contextId = "abilityClient")
public interface AbilityClient {
    @GetMapping ("/hello/{id}")
    String hello(@PathVariable("id") Integer id);

    @PostMapping("/sendMail")
    Result notice(@RequestBody @Validated EmailDto emailDto);
}
